const { Tab } = require('../../assets/libs/zanui/index');

var app = getApp();
Page(Object.assign({}, Tab, {
  data: {
		cdnUrl: '',
		isHidden: true,
	
		/* 自定义导航栏参数 */
		loading: false,
		color: '#FFFFFF',
		background: '#FFFFFF',
		show: true,
		animated: false,
		back: true,
		title: "用户协议",
		
		userPrivacy: null
  },
	/* 获取商品信息 */
	userPrivacy: function(){
		var that = this;
		app.request('/addons/cms/wxapp.common/userPrivacy', {}, function (data, ret) {//获取地址信息
		  that.setData({
				userPrivacy: data
		  });
		}, function (data, ret) {
			app.error(ret.msg);
			setTimeout(function(){
				wx.navigateBack({});
			},2000)
		});
		
	},
  
  onLoad: function () {
    var that = this;
		that.userPrivacy();
		that.setData({
			cdnUrl: app.cdnUrl,
		});
  },
  onShareAppMessage: function () {
    return {
      title: '',
      desc: '',
      path: '/page/index/index'
    }
  }
}))
